/* Start Header *****************************************************************/
/*!
\file    Timer.cpp
\author  Li YeWEi
\par     y.li\@digipen.edu
\date    September 28, 2011
\brief
	interface for timer.cpp
	
Copyright (C) 2011 DigiPen Institute of Technology.
Reproduction or disclosure of this file or its contents without the prior 
written consent of DigiPen Institute of Technology is prohibited.
*/
/* End Header *******************************************************************/

#ifndef THC_MYTIMER_H
#define THC_MYTIMER_H


//declare delta time as a global varaible used in whole engines.
extern float delta_time;

  class Timer
  {
  public:

	  Timer();

	//static class
	static Timer* GetInstance();
    
    void UpdateCurrTime();
    void UpdateNewTime();
    void UpdateFrequency();
    void UpdateDeltaTime();
    float GetDeltaTime();
    float GetFPS();
    void SetFPSLockRate( float fpslRate );
    
    void FrameRateLocker();

  private:
    float cFPSLockRate;
	bool lockFrameRate;
	LONGLONG frequency;
	LARGE_INTEGER newTime;
	LARGE_INTEGER currTime;
	float delta_time; 
  };

#endif //THC_MYTIMER_H